<h2>Total Bonus </h2>
<div class="list">
  <table cellpadding="0" cellspacing="0">
    <tr>
      <th rowspan="3">Jenis Bonus</th>
      <th rowspan="3" width="100">Bonus Diperoleh</th>
      <th colspan="3">Bonus Direkap (E-Wallet)</th>
    </tr>
    <tr>
        <th rowspan="2" width="100">Cash (80%)</th>
        <th colspan="2" width="100">Non Cash (20%)</th>
    </tr>
    <tr>
        <th width="100">Produk (80%)</th>
        <th width="100">Voucher (20%)</th>
    </tr>
    <tr>
      <td><strong>Bonus Sponsor</strong></td>
      <td align="right"><?php echo number_format($summary['sponsor_bonus']); ?></td>
      <td align="right"><?php echo number_format($ewallet_cash['sponsor']); ?></td>
      <td align="right"><?php echo number_format($ewallet_products['sponsor']); ?></td>
      <td align="right"><?php echo number_format($ewallet_voucher['sponsor']); ?></td>
    </tr>
    <tr>
      <td><strong>Bonus Extra Sponsor</strong></td>
      <td align="right"><?php echo number_format($summary['extra_sponsor_bonus']); ?></td>
      <td align="right"><?php echo number_format($ewallet_cash['extra_sponsor']); ?></td>
      <td align="right"><?php echo number_format($ewallet_products['extra_sponsor']); ?></td>
      <td align="right"><?php echo number_format($ewallet_voucher['extra_sponsor']); ?></td>
    </tr>
    <tr>
      <td><strong>Bonus Prestasi</strong></td>
      <td align="right"><?php echo number_format($summary['gen_node_bonus']); ?></td>
      <td align="right"><?php echo number_format($ewallet_cash['gen_node']); ?></td>
      <td align="right"><?php echo number_format($ewallet_products['gen_node']); ?></td>
      <td align="right"><?php echo number_format($ewallet_voucher['gen_node']); ?></td>
    </tr>
    <tr>
      <td><strong>Bonus Pasangan</strong></td>
      <td align="right"><?php echo number_format($summary['match_bonus']); ?></td>
      <td align="right"><?php echo number_format($ewallet_cash['match']); ?></td>
      <td align="right"><?php echo number_format($ewallet_products['match']); ?></td>
      <td align="right"><?php echo number_format($ewallet_voucher['match']); ?></td>
    </tr>
    <tr>
      <td><strong>Bonus Duplikasi Pasangan</strong></td>
      <td align="right"><?php echo number_format($summary['gen_match_bonus']); ?></td>
      <td align="right"><?php echo number_format($ewallet_cash['gen_match']); ?></td>
      <td align="right"><?php echo number_format($ewallet_products['gen_match']); ?></td>
      <td align="right"><?php echo number_format($ewallet_voucher['gen_match']); ?></td>
    </tr>
    <tr>
      <td><strong>Bonus Spiilover</strong></td>
      <td align="right"><?php echo number_format($summary['matrix_node_bonus']); ?></td>
      <td align="right"><?php echo number_format($ewallet_cash['matrix_node']); ?></td>
      <td align="right"><?php echo number_format($ewallet_products['matrix_node']); ?></td>
      <td align="right"><?php echo number_format($ewallet_voucher['matrix_node']); ?></td>
    </tr>
    <tr>
      <td><strong>Bonus Level Board</strong></td>
      <td align="right"><?php echo number_format($summary['board_level_bonus']); ?></td>
      <td align="right"><?php echo number_format($ewallet_cash['board_level']); ?></td>
      <td align="right"><?php echo number_format($ewallet_products['board_level']); ?></td>
      <td align="right"><?php echo number_format($ewallet_voucher['board_level']); ?></td>
    </tr>
    <tr>
      <td><strong>Bonus Fly Board</strong></td>
      <td align="right"><?php echo number_format($summary['board_fly_bonus']); ?></td>
      <td align="right"><?php echo number_format($ewallet_cash['board_fly']); ?></td>
      <td align="right"><?php echo number_format($ewallet_products['board_fly']); ?></td>
      <td align="right"><?php echo number_format($ewallet_voucher['board_fly']); ?></td>
    </tr>
    <tr class="title">
      <td><strong>TOTAL</strong></td>
      <td align="right"><?php echo number_format($summary['total_bonus']); ?></td>
      <td align="right"><?php echo number_format($ewallet_cash['total_bonus']); ?></td>
      <td align="right"><?php echo number_format($ewallet_products['total_bonus']); ?></td>
      <td align="right"><?php echo number_format($ewallet_voucher['total_bonus']); ?></td>
    </tr>
  </table>
</div>
<br /><br />
<h2>Bonus Hari Ini</h2>
<div class="list">
  <table cellpadding="0" cellspacing="0">
    <tr>
      <th>Jenis Bonus</th>
      <th width="220">Bonus</th>
    </tr>
    <tr>
      <td><strong>Bonus Sponsor</strong></td>
      <td align="right"><?php echo number_format($today['sponsor_bonus']); ?></td>
    </tr>
    <tr>
      <td><strong>Bonus Extra Sponsor</strong></td>
      <td align="right"><?php echo number_format($today['extra_sponsor_bonus']); ?></td>
    </tr>
    <tr>
      <td><strong>Bonus Prestasi</strong></td>
      <td align="right"><?php echo number_format($today['gen_node_bonus']); ?></td>
    </tr>
    <tr>
      <td><strong>Bonus Pasangan</strong></td>
      <td align="right"><?php echo number_format($today['match_bonus']); ?></td>
    </tr>
    <tr>
      <td><strong>Bonus Duplikasi Pasangan</strong></td>
      <td align="right"><?php echo number_format($today['gen_match_bonus']); ?></td>
    </tr>
    <tr>
      <td><strong>Bonus Spiilover</strong></td>
      <td align="right"><?php echo number_format($today['matrix_node_bonus']); ?></td>
    </tr>
    <tr>
      <td><strong>Bonus Level Board</strong></td>
      <td align="right"><?php echo number_format($today['board_level_bonus']); ?></td>
    </tr>
    <tr>
      <td><strong>Bonus Fly Board</strong></td>
      <td align="right"><?php echo number_format($today['board_fly_bonus']); ?></td>
    </tr>
    <tr class="title">
      <td><strong>TOTAL</strong></td>
      <td align="right"><?php echo number_format($today['total_bonus']); ?></td>
    </tr>
  </table>
</div>